{% load static %}<!DOCTYPE html>
<html lang="en">
  <head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
    <meta name="description" content="{% block description %}{% endblock %}" />
    <meta name="keywords" content="{% block keywords %}{% endblock %}" />
    <meta name="viewport" content="{% block viewport %}width=device-width"{% endblock %}>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">

    <title>{% block title %}iyinyue{% endblock title %}</title>

    <!-- HTML5 shim, for IE6-8 support of HTML5 elements -->
    <!--[if lt IE 9]>
      <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->

    <link rel="icon" type="image/gif" href="{% static 'img/favicon.png' %}?v={{version}}">

    {% block css %}
    <link rel="stylesheet" href="{% static 'css/spectre.min.css' %}?v={{version}}">
    <link rel="stylesheet" href="{% static 'css/spectre-exp.min.css' %}?v={{version}}">
    <link rel="stylesheet" href="{% static 'css/spectre-icons.min.css' %}?v={{version}}">
    <link href="{% static 'css/styles.css' %}?v={{version}}" rel="stylesheet">
    {% endblock %}

  </head>

  <body>
    <div class="container">

      <div class="columns col-10 col-lg-10 col-md-10 col-sm-12 col-lg-auto col-md-auto col-sm-auto col-mx-auto" style="margin-top: 16px;" id="navbar">
        <div class="column">
          <header class="navbar">
            <section class="navbar-center">
              <img src="{% static 'img/logo.svg' %}" style="width: 48px; height: 48px;" class="navbar-brand mr-2" />
            </section>
            <section class="navbar-section">
              {% verbatim vue %}
              <a href="{{ brand_url }}" class="navbar-brand mr-2" v-if="brand"><h1>{{ brand }}</h1></a>
              <a href="/school" class="navbar-brand mr-2" v-else>iYinyue</a>
              {% endverbatim vue %}
              {% block navsection %}
              {% endblock navsection %}
            </section>
            {% if user.first_name %}
            <section class="navbar-section">
              <span class="chip" id="user-name" v-on:click="user_menu">
                <img src="{{ user.userprofile.icon.url }}" class="avatar avatar-sm">
                <a href="/accounts/profile?id={{ user.pk }}">{{ user.first_name }}</a><a href="/accounts/logout" class="btn btn-clear tooltip tooltip-bottom" data-tooltip="退出" aria-label="Close" role="button"></a>
              </span>
            </section>
            {% endif %}
          </header>
        </div>
      </div>

    </div> <!-- /container -->

    {% block content %}
      <p>Use this document as a way to quick start any new project.</p>
    {% endblock content %}


    <div class="qrcode">
      <div id="qrcode" class="qrcode-content"></div>
      <a href="javascript:qrcode();" class="btn qrcode-toggle text-center centered">手机查看</a>
    </div>

    <!-- Le javascript
    ================================================== -->
    <!-- Placed at the end of the document so the pages load faster -->
    <script src="https://cdn.jsdelivr.net/vue/1.0.7/vue.min.js"></script>
    <script src="https://cdn.bootcss.com/vue-resource/1.3.4/vue-resource.min.js"></script>
    <script type="text/javascript">
      function _P(name)
      {
           var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");
           var r = window.location.search.substr(1).match(reg);
           if(r!=null)return  unescape(r[2]); return null;
      }
    </script>
    {% block javascript %}
    <script src="{% static 'js/qrcode.js' %}?v={{version}}"></script>
    <script src="{% static 'js/scripts.js' %}?v={{version}}"></script>
    {% endblock javascript %}
  </body>
</html>
